package com.qianfeng.day2.myclient1.controller;

import com.qianfeng.day2.myclient1.model.TbBd;
import com.qianfeng.day2.myclient1.server.BdService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;

@Controller
public class BdController {
    @Autowired
    private BdService bdService;
    @RequestMapping("/hhhh")
    public String Bd(){
        List<TbBd> list = bdService.findAll();
        for (TbBd tbBd : list) {
            System.out.println(tbBd);
        }
        return "index1.html";
    }
}
